<?php if (!defined('THINK_PATH')) exit();?><!doctype html>
<html>
<head>
    <meta charset="UTF-8">
    <title>后台管理</title>
    <link rel="stylesheet" type="text/css" href="/Public/Admin/css/common.css"/>
    <link rel="stylesheet" type="text/css" href="/Public/Admin/css/main.css"/>
    <script type="text/javascript" src="/Public/Admin/js/libs/modernizr.min.js"></script>
    <script type="text/javascript" src="/Public/ueditor/ueditor.config.js"></script>
    <script type="text/javascript" src="/Public/ueditor/ueditor.all.min.js"></script>
    <script type="text/javascript" src="/Public/ueditor/lang/zh-cn/zh-cn.js"></script>
</head>
<body>
<div class="topbar-wrap white">
    <div class="topbar-inner clearfix">
        <div class="topbar-logo-wrap clearfix">
            <h1 class="topbar-logo none"><a href="index.html" class="navbar-brand">/Public后台管理</a></h1>
            <ul class="navbar-list clearfix">
                <li><a class="on" href="index.html">首页</a></li>
                <li><a href="/index.php/Home" target="_blank">网站首页</a></li>
            </ul>
        </div>
        <div class="top-info-wrap">
            <ul class="top-info-list clearfix">
                <li><a href="#">管理员<?php echo $_SESSION['username']; ?></a></li>
                <li><a href="/index.php/Admin/Admin/edit/id/<?php echo $_SESSION['id'];?>">修改密码</a></li>
                <li><a href="/index.php/Admin/Admin/logout">退出</a></li>
            </ul>
        </div>
    </div>
</div>
<!--引入头部栏-->
<div class="container clearfix">
  <div class="sidebar-wrap">
    <div class="sidebar-title">
        <h1>菜单</h1>
    </div>
    <div class="sidebar-content">
        <ul class="sidebar-list">
            <li>
                <a href="#"><i class="icon-font">&#xe003;</i>常用操作</a>
                <ul class="sub-menu">
                    <li><a href="/index.php/Admin/Article/lst"><i class="icon-font">&#xe008;</i>文章管理</a></li>
                    <li><a href="/index.php/Admin/Cate/lst"><i class="icon-font">&#xe006;</i>分类管理</a></li>
                    <li><a href="/index.php/Admin/Link/lst"><i class="icon-font">&#xe052;</i>友情链接</a></li>
                    <li><a href="/index.php/Admin/Admin/lst"><i class="icon-font">&#xe033;</i>管理员管理</a></li>
                </ul>
            </li>
        </ul>
    </div>
</div>
<!--//引入左部栏目-->
    <!--/sidebar-->
    <div class="main-wrap">

        <div class="crumb-wrap">
            <div class="crumb-list"><i class="icon-font"></i><a href="/jscss/admin/design/">首页</a><span class="crumb-step">&gt;</span><a class="crumb-name" href="/jscss/admin/design/">文章管理管理</a><span class="crumb-step">&gt;</span><span>新增作品</span></div>
        </div>
        <div class="result-wrap">
            <div class="result-content">
                <form action="<?php echo U('Admin/article/edit');?>" method="post" id="myform" name="myform" enctype="multipart/form-data">
                    <table class="insert-tab" width="100%">
                        <tbody>
                            <tr>
                                <th><i class="require-red">*</i>文章标题：</th>
                                <td>
                                    <input type="hidden" name="id" value="<?php echo ($edit["id"]); ?>">
                                    <input class="common-text required" id="title" name="title" size="50" value="<?php echo ($edit["title"]); ?>" type="text">
                                </td>
                            </tr>
                            <tr>
                                <th>文章描述：</th>
                                <td><textarea name="desc" class="common-textarea"  cols="30" style="width: 469px;height:80px;" rows="10"><?php echo ($edit["desc"]); ?></textarea></td>
                            </tr>
                            <tr>
                                <th><i class="require-red">*</i>缩略图：</th>
                                <td>
                                    <input type="file" class="" id="pic" name="pic" size="50" value="" >
                                    <img src="/Uploads/<?php echo ($edit["pic"]); ?>" alt="">
                                </td>
                            </tr>
                            <tr>
                              <th><i class="require-red">*</i>所属栏目：</th>
                              <td>
                                  <select name="cateid">
                                    <option value="0">栏目分类</option>
                                    <?php if(is_array($cateinfo)): $i = 0; $__LIST__ = $cateinfo;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$cate): $mod = ($i % 2 );++$i; if($cate['id'] == $edit['cateid']): ?><option value="<?php echo ($cate["id"]); ?>" selected><?php echo ($cate["catename"]); ?></option>
                                        <?php else: ?>
                                        <option value="<?php echo ($cate["id"]); ?>"><?php echo ($cate["catename"]); ?></option><?php endif; endforeach; endif; else: echo "" ;endif; ?>
                                  </select>
                              </td>
                            </tr>
                            <tr>
                                <th>文章内容：</th>
                                <td><textarea name="content" id="content" ><?php echo ($edit["content"]); ?></textarea></td>
                            </tr>

                            <tr>
                                <th></th>
                                <td>
                                    <input class="btn btn-primary btn6 mr10" value="提交" type="submit">
                                    <input class="btn btn6" onclick="history.go(-1)" value="返回" type="button">
                                </td>
                            </tr>
                        </tbody></table>
                </form>
            </div>
        </div>

    </div>
    <!--/main-->
</div>
<script type="text/javascript">
  //实例化编辑器
  //建议使用工厂方法getEdit创建和引用编辑器实例，如果在某个闭包下引用该编辑器，直接调用UE.getEditor('editor')就能拿到相关实例
  UE.getEditor('content',{initialFrameWidth:1000,initialFrameHeight:200,});
</script>
</body>
</html>